<?php
/*
 * @ https://EasyToYou.eu - IonCube v11 Decoder Online
 * @ PHP 7.2 & 7.3
 * @ Decoder version: 1.1.6
 * @ Release: 10/08/2022
 */

// Decoded file for php version 71.
class EncryptUtil
{
    public static function encrypt($key, $data)
    {
        $key = substr($key, 0, 16);
        $iv = substr(md5($key), 0, 16);
        $td = mcrypt_module_open(MCRYPT_RIJNDAEL_128, "", MCRYPT_MODE_CBC, "");
        mcrypt_generic_init($td, $key, $iv);
        $encrypted = mcrypt_generic($td, $data);
        mcrypt_generic_deinit($td);
        mcrypt_module_close($td);
        return base64_encode($encrypted);
    }
    public static function decrypt($key, $data)
    {
        $key = substr($key, 0, 16);
        $iv = substr(md5($key), 0, 16);
        $td = mcrypt_module_open(MCRYPT_RIJNDAEL_128, "", MCRYPT_MODE_CBC, "");
        mcrypt_generic_init($td, $key, $iv);
        $decode = base64_decode($data);
        $dencrypted = mdecrypt_generic($td, $decode);
        mcrypt_generic_deinit($td);
        mcrypt_module_close($td);
        return $dencrypted;
    }
}

?>